import { createRouter, createWebHashHistory, RouteRecordRaw } from 'vue-router'

import Home from '@/views/Home.vue'
import Jiading from '@/views/jiading1.vue'
import Putuo from '@/views/Putuo.vue'
import Hongkou from '@/views/Hongkou.vue'
import Yangpu from '@/views/Yangpu.vue'
import Songjiang from '@/views/Songjiang.vue'
import ModalTest from '@/views/ModalTest.vue'

const routes: Array<RouteRecordRaw> = [
    {
        path: '/',
        name: 'home',
        component: Home
    },
    {
        path: '/jiading',
        name: 'jiading',
        component: Jiading // 嘉定
    },
    {
        path: '/putuo',
        name: 'putuo',
        component: Putuo // 普陀
    },
    {
        path: '/hongkou',
        name: 'hongkou',
        component: Hongkou // 虹口
    },
    {
        path: '/yangpu',
        name: 'yangpu',
        component: Yangpu // 杨浦
    },
    {
        path: '/songjiang',
        name: 'songjiang',
        component: Songjiang // 松江
    },
    {
        path: '/modaltest',
        name: 'modaltest',
        component: ModalTest // 弹窗
    }
]

const router = createRouter({
    history: createWebHashHistory(),
    routes
})

export default router
